<%--
  Created by IntelliJ IDEA.
  User: 29688
  Date: 2021/4/13
  Time: 21:14
  To change this template use File | Settings | File Templates.
--%>
<%--
  Created by IntelliJ IDEA.
  User: 29688
  Date: 2021/3/22
  Time: 17:23
  To change this template use File | Settings | File Templates.
--%>
<%--
  Created by IntelliJ IDEA.
  User: 29688
  Date: 2021/3/28
  Time: 13:07
  To change this template use File | Settings | File Templates.
--%>
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<html>
<head>
    <meta charset="utf-8">
    <title>历史订单</title>
    <meta name="renderer" content="webkit">
    <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
    <meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1">
    <link rel="stylesheet" href="../../../layui-v2.5.7/layui/css/layui.css" media="all">
    <script src="../../../layui-v2.5.7/layui/layui.js" charset="utf-8"></script>
    <script src="../../../js/jquery.js"></script>
</head>
<body>

<table class="layui-hide" id="test" lay-filter="test">
</table>
<script>
    layui.use(['table','layer','util'], function () {
        var table = layui.table;
        var util =layui.util;
        table.render({
            elem: '#test'
            , url: '/user/order/orderDetailSelectList?oid='+${oid}
            , title: '用户数据表'
            , cols: [[
                /*设置序号*/
                {type: 'numbers', fixed: 'left', title: "id"},
                {type: 'checkbox', fixed: 'left'}
                , {field: 'oid', title: '订单号', width: 160, edit: 'text', sort: true,hide: true}
                , {field: 'bid', title: '书号', width: 20, edit: 'text', sort: true}
                , {field: 'description', title: '描述信息', width: 100, edit: 'text'}
                , {field: 'bname', title: '书名', width: 100, edit: 'text', sort: true}
                , {field: 'count', title: '数量', width: 20, edit: 'text', sort: true}
            ]]
            , page: true,
            skin: 'row',
            even: 'true',
            id: 'bookTable'
        });
        //监听行工具事件
        table.on('tool(test)', function (obj) {
            var data = obj.data;
            if (obj.event === 'edit') {
                layer.confirm('真的删除行么', function (index) {
                    obj.del();
                    layer.close(index);

                });
            }

        });
    });

</script>

</body>
</html>

